package com.djl.mvc.controller;

import com.djl.crowd.entity.Admin;
import com.djl.service.AdminService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;


@Controller
public class TestHandler {

    @Autowired
    private AdminService adminService;

    @RequestMapping("/test/ssm.html")
    public String testSmm(ModelMap map){
        String a = null;
        System.out.println(a.length());
        List<Admin> adminList = adminService.getAll();
        map.addAttribute("adminList",adminList);
        return "target";
    }

}
